import request from '@/utils/request'

// 查询外协生产商列表
export function listOutsourcedManufacture(query) {
  return request({
    url: '/mes/md/outsourcedManufacture/list',
    method: 'get',
    params: query
  })
}

// 查询外协生产商详细
export function getOutsourcedManufacture(manufactureId) {
  return request({
    url: '/mes/md/outsourcedManufacture/' + manufactureId,
    method: 'get'
  })
}

// 新增外协生产商
export function addOutsourcedManufacture(data) {
  return request({
    url: '/mes/md/outsourcedManufacture',
    method: 'post',
    data: data
  })
}

// 修改外协生产商
export function updateOutsourcedManufacture(data) {
  return request({
    url: '/mes/md/outsourcedManufacture',
    method: 'put',
    data: data
  })
}

// 删除外协生产商
export function delOutsourcedManufacture(manufactureId) {
  return request({
    url: '/mes/md/outsourcedManufacture/' + manufactureId,
    method: 'delete'
  })
}
